package com.dhcc.cdc.busi.entity;

import com.baomidou.mybatisplus.annotations.TableField;
import com.baomidou.mybatisplus.annotations.TableId;
import com.baomidou.mybatisplus.annotations.TableName;
import com.baomidou.mybatisplus.enums.IdType;
import com.dhcc.cdc.sys.entity.CdcDataEntity;
import com.dhcc.cdc.util.ICdcDataSrv;
import com.dhcc.core.framework.base.entity.DataEntity;
import org.springframework.format.annotation.DateTimeFormat;

import java.util.Date;


/**
 * 患者就诊信息
 * 
 * @ClassName: CdcEpisodeEntity
 * @Description: TODO
 * @author jumper
 * @date 2021-03-15 10:20:08
 */
@TableName("t_cdc_bs_episode") 
public class CdcEpisodeEntity extends DataEntity<CdcEpisodeEntity> implements ICdcDataSrv{
	private static final long serialVersionUID = 1L;
	@TableId(value = "id", type = IdType.AUTO)
	private Long id;
	
	//索引码
	private String xcode;	
	//就诊流水号
	private String episodeNum;
	//患者主索引
	private String patientCode;	
	//就诊类型
	private Long busAdmTypeId;
    @TableField(exist = false)
    private CdcDictionaryEntity busAdmType;	
	//就诊状态
	private Long busAdmStatusId;
    @TableField(exist = false)
    private CdcDictionaryEntity busAdmStatus;	
	//电子健康码
	private String healthCode;	
	//姓名
	private String name;	
	//性别
	private String gender;	
	//国籍
	private String nationality;	
	//民族
	private String nation;	
	//出生日期
    @DateTimeFormat(pattern = "yyyy-MM-dd")
	private Date birthdate;	
	//年龄
	private String age;	
	//证件类型
	private String cardType;	
	//证件号码
	private String cardValue;	
	//籍贯
	private String nativePlace;	
	//工作单位
	private String company;	
	//电话
	private String telephone;	
	//邮箱
	private String email;	
	//联系人
	private String contactor;	
	//联系人电话
	private String contactorPhone;	
	//职业
	private String career;	
	//血型ABO
	private String bloodAbo;	
	//血型Rh
	private String bloodRh;	
	//登记号
	private String registNum;	
	//病案号
	private String mrNum;	
	//户籍所在地省
	private String nativeProvince;	
	//户籍所在地市
	private String nativeCity;	
	//户籍所在地县
	private String nativeCounty;	
	//户籍所在地乡
	private String nativeTown;	
	//户籍所在地详细描述
	private String nativeAddress;	
	//现住址所在地省
	private String nowProvince;	
	//现住址所在地市
	private String nowCity;	
	//现住址所在地县
	private String nowCounty;	
	//现住址所在地乡
	private String nowTown;	
	//现住址详细描述
	private String nowAddress;	
	//死亡标志
	private Integer isDeath;	
	//死亡日期
    @DateTimeFormat(pattern = "yyyy-MM-dd HH:mm:ss")
	private Date deathDate;	
	//住院次数
	private Integer admNums;
	//门急诊日期
	@DateTimeFormat(pattern = "yyyy-MM-dd HH:mm:ss")
	private Date oeDate;
	//入院日期
    @DateTimeFormat(pattern = "yyyy-MM-dd HH:mm:ss")
	private Date admDate;	
	//就诊科室
	private Long admLocId;	
	//就诊科室Desc
	private String admLocDesc;	
	//就诊病区
	private Long admWardId;	
	//就诊病区Desc
	private String admWardDesc;	
	//就诊房间
	private String admRoom;	
	//就诊床位
	private String admBed;	
	//主管医生
	private Long admDoctorId;	
	//主管医生姓名
	private String admDoctorName;	
	//出院日期
    @DateTimeFormat(pattern = "yyyy-MM-dd HH:mm:ss")
	private Date dishDate;	
	//住院天数
	private Integer admDays;	
	//是否初诊
	private Integer isNewly;	
	//是否新生儿
	private Integer isNewborn;	
	//新生儿出生体重(g)
	private Integer bornWeight;	
	//新生儿入院体重(g)
	private Integer admWeight;	
	//业务数据类型
	private Long dataId;
    @TableField(exist = false)
    private CdcDataEntity data;	
	//是否有效
	private Integer isActive;
	//是否已编目
	private Integer isCoded;
	//编目日期
	@DateTimeFormat(pattern = "yyyy-MM-dd HH:mm:ss")
	private Date codeDate;
	//科室统计数量
	@TableField(exist = false)
	private Long deptCount;
	//是否做了VTE评估
	private Integer isEvaluate;

	/**
	 *
	 * 获取：科室统计数量
	 */
	public Long getDeptCount() {
		return deptCount;
	}

	/**
	 * 设置：科室统计数量
	 */
	public void setDeptCount(Long deptCount) {
		this.deptCount = deptCount;
	}

	/**
	 * 设置：索引码
	 */
	public void setXcode(String xcode) {
		this.xcode = xcode;
	}
	/**
	 * 获取：索引码
	 */
	public String getXcode() {
		return xcode;
	}
	/**
	 * 设置：就诊流水号
	 */
	public void setEpisodeNum(String episodeNum) {
		this.episodeNum = episodeNum;
	}
	/**
	 * 获取：就诊流水号
	 */
	public String getEpisodeNum() {
		return episodeNum;
	}
	/**
	 * 设置：患者主索引
	 */
	public void setPatientCode(String patientCode) {
		this.patientCode = patientCode;
	}
	/**
	 * 获取：患者主索引
	 */
	public String getPatientCode() {
		return patientCode;
	}
	/**
	 * 设置：就诊类型
	 */
	public void setBusAdmTypeId(Long busAdmTypeId) {
		this.busAdmTypeId = busAdmTypeId;
	}
	/**
	 * 获取：就诊类型
	 */
	public Long getBusAdmTypeId() {
		return busAdmTypeId;
	}
	/**
	 * 设置：就诊状态
	 */
	public void setBusAdmStatusId(Long busAdmStatusId) {
		this.busAdmStatusId = busAdmStatusId;
	}
	/**
	 * 获取：就诊状态
	 */
	public Long getBusAdmStatusId() {
		return busAdmStatusId;
	}
	/**
	 * 设置：电子健康码
	 */
	public void setHealthCode(String healthCode) {
		this.healthCode = healthCode;
	}
	/**
	 * 获取：电子健康码
	 */
	public String getHealthCode() {
		return healthCode;
	}
	/**
	 * 设置：姓名
	 */
	public void setName(String name) {
		this.name = name;
	}
	/**
	 * 获取：姓名
	 */
	public String getName() {
		return name;
	}
	/**
	 * 设置：性别
	 */
	public void setGender(String gender) {
		this.gender = gender;
	}
	/**
	 * 获取：性别
	 */
	public String getGender() {
		return gender;
	}
	/**
	 * 设置：国籍
	 */
	public void setNationality(String nationality) {
		this.nationality = nationality;
	}
	/**
	 * 获取：国籍
	 */
	public String getNationality() {
		return nationality;
	}
	/**
	 * 设置：民族
	 */
	public void setNation(String nation) {
		this.nation = nation;
	}
	/**
	 * 获取：民族
	 */
	public String getNation() {
		return nation;
	}
	/**
	 * 设置：出生日期
	 */
	public void setBirthdate(Date birthdate) {
		this.birthdate = birthdate;
	}
	/**
	 * 获取：出生日期
	 */
	public Date getBirthdate() {
		return birthdate;
	}
	/**
	 * 设置：年龄
	 */
	public void setAge(String age) {
		this.age = age;
	}
	/**
	 * 获取：年龄
	 */
	public String getAge() {
		return age;
	}
	/**
	 * 设置：证件类型
	 */
	public void setCardType(String cardType) {
		this.cardType = cardType;
	}
	/**
	 * 获取：证件类型
	 */
	public String getCardType() {
		return cardType;
	}
	/**
	 * 设置：证件号码
	 */
	public void setCardValue(String cardValue) {
		this.cardValue = cardValue;
	}
	/**
	 * 获取：证件号码
	 */
	public String getCardValue() {
		return cardValue;
	}
	/**
	 * 设置：籍贯
	 */
	public void setNativePlace(String nativePlace) {
		this.nativePlace = nativePlace;
	}
	/**
	 * 获取：籍贯
	 */
	public String getNativePlace() {
		return nativePlace;
	}
	/**
	 * 设置：工作单位
	 */
	public void setCompany(String company) {
		this.company = company;
	}
	/**
	 * 获取：工作单位
	 */
	public String getCompany() {
		return company;
	}
	/**
	 * 设置：电话
	 */
	public void setTelephone(String telephone) {
		this.telephone = telephone;
	}
	/**
	 * 获取：电话
	 */
	public String getTelephone() {
		return telephone;
	}
	/**
	 * 设置：邮箱
	 */
	public void setEmail(String email) {
		this.email = email;
	}
	/**
	 * 获取：邮箱
	 */
	public String getEmail() {
		return email;
	}
	/**
	 * 设置：联系人
	 */
	public void setContactor(String contactor) {
		this.contactor = contactor;
	}
	/**
	 * 获取：联系人
	 */
	public String getContactor() {
		return contactor;
	}
	/**
	 * 设置：联系人电话
	 */
	public void setContactorPhone(String contactorPhone) {
		this.contactorPhone = contactorPhone;
	}
	/**
	 * 获取：联系人电话
	 */
	public String getContactorPhone() {
		return contactorPhone;
	}
	/**
	 * 设置：职业
	 */
	public void setCareer(String career) {
		this.career = career;
	}
	/**
	 * 获取：职业
	 */
	public String getCareer() {
		return career;
	}
	/**
	 * 设置：血型ABO
	 */
	public void setBloodAbo(String bloodAbo) {
		this.bloodAbo = bloodAbo;
	}
	/**
	 * 获取：血型ABO
	 */
	public String getBloodAbo() {
		return bloodAbo;
	}
	/**
	 * 设置：血型Rh
	 */
	public void setBloodRh(String bloodRh) {
		this.bloodRh = bloodRh;
	}
	/**
	 * 获取：血型Rh
	 */
	public String getBloodRh() {
		return bloodRh;
	}
	/**
	 * 设置：登记号
	 */
	public void setRegistNum(String registNum) {
		this.registNum = registNum;
	}
	/**
	 * 获取：登记号
	 */
	public String getRegistNum() {
		return registNum;
	}
	/**
	 * 设置：病案号
	 */
	public void setMrNum(String mrNum) {
		this.mrNum = mrNum;
	}
	/**
	 * 获取：病案号
	 */
	public String getMrNum() {
		return mrNum;
	}
	/**
	 * 设置：户籍所在地省
	 */
	public void setNativeProvince(String nativeProvince) {
		this.nativeProvince = nativeProvince;
	}
	/**
	 * 获取：户籍所在地省
	 */
	public String getNativeProvince() {
		return nativeProvince;
	}
	/**
	 * 设置：户籍所在地市
	 */
	public void setNativeCity(String nativeCity) {
		this.nativeCity = nativeCity;
	}
	/**
	 * 获取：户籍所在地市
	 */
	public String getNativeCity() {
		return nativeCity;
	}
	/**
	 * 设置：户籍所在地县
	 */
	public void setNativeCounty(String nativeCounty) {
		this.nativeCounty = nativeCounty;
	}
	/**
	 * 获取：户籍所在地县
	 */
	public String getNativeCounty() {
		return nativeCounty;
	}
	/**
	 * 设置：户籍所在地乡
	 */
	public void setNativeTown(String nativeTown) {
		this.nativeTown = nativeTown;
	}
	/**
	 * 获取：户籍所在地乡
	 */
	public String getNativeTown() {
		return nativeTown;
	}
	/**
	 * 设置：户籍所在地详细描述
	 */
	public void setNativeAddress(String nativeAddress) {
		this.nativeAddress = nativeAddress;
	}
	/**
	 * 获取：户籍所在地详细描述
	 */
	public String getNativeAddress() {
		return nativeAddress;
	}
	/**
	 * 设置：现住址所在地省
	 */
	public void setNowProvince(String nowProvince) {
		this.nowProvince = nowProvince;
	}
	/**
	 * 获取：现住址所在地省
	 */
	public String getNowProvince() {
		return nowProvince;
	}
	/**
	 * 设置：现住址所在地市
	 */
	public void setNowCity(String nowCity) {
		this.nowCity = nowCity;
	}
	/**
	 * 获取：现住址所在地市
	 */
	public String getNowCity() {
		return nowCity;
	}
	/**
	 * 设置：现住址所在地县
	 */
	public void setNowCounty(String nowCounty) {
		this.nowCounty = nowCounty;
	}
	/**
	 * 获取：现住址所在地县
	 */
	public String getNowCounty() {
		return nowCounty;
	}
	/**
	 * 设置：现住址所在地乡
	 */
	public void setNowTown(String nowTown) {
		this.nowTown = nowTown;
	}
	/**
	 * 获取：现住址所在地乡
	 */
	public String getNowTown() {
		return nowTown;
	}
	/**
	 * 设置：现住址详细描述
	 */
	public void setNowAddress(String nowAddress) {
		this.nowAddress = nowAddress;
	}
	/**
	 * 获取：现住址详细描述
	 */
	public String getNowAddress() {
		return nowAddress;
	}
	/**
	 * 设置：死亡标志
	 */
	public void setIsDeath(Integer isDeath) {
		this.isDeath = isDeath;
	}
	/**
	 * 获取：死亡标志
	 */
	public Integer getIsDeath() {
		return isDeath;
	}
	/**
	 * 设置：死亡日期
	 */
	public void setDeathDate(Date deathDate) {
		this.deathDate = deathDate;
	}
	/**
	 * 获取：死亡日期
	 */
	public Date getDeathDate() {
		return deathDate;
	}
	/**
	 * 设置：住院次数
	 */
	public void setAdmNums(Integer admNums) {
		this.admNums = admNums;
	}
	/**
	 * 获取：住院次数
	 */
	public Integer getAdmNums() {
		return admNums;
	}
	/**
	 * 设置：入院日期
	 */
	public void setAdmDate(Date admDate) {
		this.admDate = admDate;
	}
	/**
	 * 获取：入院日期
	 */
	public Date getAdmDate() {
		return admDate;
	}
	/**
	 * 设置：就诊科室
	 */
	public void setAdmLocId(Long admLocId) {
		this.admLocId = admLocId;
	}
	/**
	 * 获取：就诊科室
	 */
	public Long getAdmLocId() {
		return admLocId;
	}
	/**
	 * 设置：就诊科室Desc
	 */
	public void setAdmLocDesc(String admLocDesc) {
		this.admLocDesc = admLocDesc;
	}
	/**
	 * 获取：就诊科室Desc
	 */
	public String getAdmLocDesc() {
		return admLocDesc;
	}
	/**
	 * 设置：就诊病区
	 */
	public void setAdmWardId(Long admWardId) {
		this.admWardId = admWardId;
	}
	/**
	 * 获取：就诊病区
	 */
	public Long getAdmWardId() {
		return admWardId;
	}
	/**
	 * 设置：就诊病区Desc
	 */
	public void setAdmWardDesc(String admWardDesc) {
		this.admWardDesc = admWardDesc;
	}
	/**
	 * 获取：就诊病区Desc
	 */
	public String getAdmWardDesc() {
		return admWardDesc;
	}
	/**
	 * 设置：就诊房间
	 */
	public void setAdmRoom(String admRoom) {
		this.admRoom = admRoom;
	}
	/**
	 * 获取：就诊房间
	 */
	public String getAdmRoom() {
		return admRoom;
	}
	/**
	 * 设置：就诊床位
	 */
	public void setAdmBed(String admBed) {
		this.admBed = admBed;
	}
	/**
	 * 获取：就诊床位
	 */
	public String getAdmBed() {
		return admBed;
	}
	/**
	 * 设置：主管医生
	 */
	public void setAdmDoctorId(Long admDoctorId) {
		this.admDoctorId = admDoctorId;
	}
	/**
	 * 获取：主管医生
	 */
	public Long getAdmDoctorId() {
		return admDoctorId;
	}
	/**
	 * 设置：主管医生姓名
	 */
	public void setAdmDoctorName(String admDoctorName) {
		this.admDoctorName = admDoctorName;
	}
	/**
	 * 获取：主管医生姓名
	 */
	public String getAdmDoctorName() {
		return admDoctorName;
	}
	/**
	 * 设置：出院日期
	 */
	public void setDishDate(Date dishDate) {
		this.dishDate = dishDate;
	}
	/**
	 * 获取：出院日期
	 */
	public Date getDishDate() {
		return dishDate;
	}
	/**
	 * 设置：住院天数
	 */
	public void setAdmDays(Integer admDays) {
		this.admDays = admDays;
	}
	/**
	 * 获取：住院天数
	 */
	public Integer getAdmDays() {
		return admDays;
	}
	/**
	 * 设置：是否初诊
	 */
	public void setIsNewly(Integer isNewly) {
		this.isNewly = isNewly;
	}
	/**
	 * 获取：是否初诊
	 */
	public Integer getIsNewly() {
		return isNewly;
	}
	/**
	 * 设置：是否新生儿
	 */
	public void setIsNewborn(Integer isNewborn) {
		this.isNewborn = isNewborn;
	}
	/**
	 * 获取：是否新生儿
	 */
	public Integer getIsNewborn() {
		return isNewborn;
	}
	/**
	 * 设置：新生儿出生体重(g)
	 */
	public void setBornWeight(Integer bornWeight) {
		this.bornWeight = bornWeight;
	}
	/**
	 * 获取：新生儿出生体重(g)
	 */
	public Integer getBornWeight() {
		return bornWeight;
	}
	/**
	 * 设置：新生儿入院体重(g)
	 */
	public void setAdmWeight(Integer admWeight) {
		this.admWeight = admWeight;
	}
	/**
	 * 获取：新生儿入院体重(g)
	 */
	public Integer getAdmWeight() {
		return admWeight;
	}
	/**
	 * 设置：业务数据类型
	 */
	public void setDataId(Long dataId) {
		this.dataId = dataId;
	}
	/**
	 * 获取：业务数据类型
	 */
	public Long getDataId() {
		return dataId;
	}
	/**
	 * 设置：是否有效
	 */
	public void setIsActive(Integer isActive) {
		this.isActive = isActive;
	}

	public Integer getIsCoded() {
		return isCoded;
	}

	public void setIsCoded(Integer isCoded) {
		this.isCoded = isCoded;
	}

	public Date getCodeDate() {
		return codeDate;
	}

	public void setCodeDate(Date codeDate) {
		this.codeDate = codeDate;
	}

	public Date getOeDate() {
		return oeDate;
	}

	public void setOeDate(Date oeDate) {
		this.oeDate = oeDate;
	}

	/**
	 * 获取：是否有效
	 */



	public Integer getIsActive() {
		return isActive;
	}
    public CdcDictionaryEntity getBusAdmType() {
        return busAdmType;
    }
    public void setBusAdmType(CdcDictionaryEntity busAdmType) {
        this.busAdmType = busAdmType;
    }
    public CdcDictionaryEntity getBusAdmStatus() {
        return busAdmStatus;
    }
    public void setBusAdmStatus(CdcDictionaryEntity busAdmStatus) {
        this.busAdmStatus = busAdmStatus;
    }
    public CdcDataEntity getData() {
        return data;
    }
    public void setData(CdcDataEntity data) {
        this.data = data;
    }

	public Integer getIsEvaluate() {
		return isEvaluate;
	}

	public void setIsEvaluate(Integer isEvaluate) {
		this.isEvaluate = isEvaluate;
	}

	@Override
    public long getOrganizationId() {
        if(this.data != null){
            return this.data.getOrganizationId();
        }
        return 0;
    }
}
